﻿using Microsoft.EntityFrameworkCore.Migrations;

namespace CPPProject.Migrations
{
    public partial class add3 : Migration
    {
        protected override void Up(MigrationBuilder migrationBuilder)
        {
            migrationBuilder.DropColumn(
                name: "IsAssembly",
                table: "T_Biz_Item");

            migrationBuilder.AlterColumn<decimal>(
                name: "NSeq",
                table: "T_Biz_ItemQR",
                nullable: true,
                oldClrType: typeof(string),
                oldType: "nvarchar(100)",
                oldMaxLength: 100,
                oldNullable: true);

            migrationBuilder.AddColumn<int>(
                name: "NQty",
                table: "T_Biz_Item",
                nullable: false,
                defaultValue: 0);

            migrationBuilder.AddColumn<string>(
                name: "ParentId",
                table: "T_Biz_Item",
                nullable: true);
        }

        protected override void Down(MigrationBuilder migrationBuilder)
        {
            migrationBuilder.DropColumn(
                name: "NQty",
                table: "T_Biz_Item");

            migrationBuilder.DropColumn(
                name: "ParentId",
                table: "T_Biz_Item");

            migrationBuilder.AlterColumn<string>(
                name: "NSeq",
                table: "T_Biz_ItemQR",
                type: "nvarchar(100)",
                maxLength: 100,
                nullable: true,
                oldClrType: typeof(decimal),
                oldNullable: true);

            migrationBuilder.AddColumn<string>(
                name: "IsAssembly",
                table: "T_Biz_Item",
                type: "nvarchar(max)",
                nullable: true);
        }
    }
}
